home *** CD-ROM | disk | FTP | other *** search
/ Night Owl 6 / Night Owl's Shareware - PDSI-006 - Night Owl Corp (1990).iso / 016a / mdosp401.zip / README < prev    next >
Text File  |  1991-10-27  |  18KB  |  475 lines

  1. ---------------------------------------------
  2. * MultiDos Plus Rel. 4.01 Shareware Version *
  3. * Copyright (c) 1986 - 1991  Nanosoft Inc.  *
  4. ---------------------------------------------
  5.  
  6. Welcome to MultiDos Plus, a powerful real-time multitasking shell
  7. for DOS.  MultiDos Plus is a copyrighted work of Nanosoft Inc
  8. and is NOT public domain.
  9.  
  10. If you like this product, register with us for $35, and we will
  11. send you the commercial version of MultiDos Plus ($99 value)
  12. with printed documentation.
  13.  
  14. You may freely copy and distribute this product as long as you
  15. abide by the following conditions:
  16.  
  17.     a) You may not charge any fee for making copies or sell this product.
  18.     b) You may not distribute this as part of any product or
  19.        service for which you charge a fee.
  20.     c) You must copy the product in its entirety with no changes.
  21.  
  22. If you would like to do any of the above, you must have our permission
  23. in writing.  Contact us for site licensing and royalty arrangements.
  24.  
  25. ------------
  26. * WARRANTY *
  27. ------------
  28.  
  29. This product is distributed with absolutely no warranty of
  30. any kind.
  31.  
  32. -------------------
  33. * How to Register *
  34. -------------------
  35.  
  36. Send a check for $35 to:
  37.  
  38.      Nanosoft Inc.
  39.      13 Westfield Road
  40.      Natick, MA 01760
  41.      Attn: Shareware Dept.
  42.  
  43. To register using Mastercard or Visa call (508) 651-0091.
  44.  
  45. To register by FAX send name, address, and charge card information
  46. (be sure to include expiration date) and telephone numbers
  47. to (508) 655-8860.
  48.  
  49. -------------------------------------------------------------
  50. * Differences between the commercial and shareware versions *
  51. -------------------------------------------------------------
  52.  
  53. The commercial version which you will receive when you
  54. register has the following additional features:
  55.  
  56.    a) It supports 64 tasks instead of the 3 tasks supported
  57.    by this version.
  58.  
  59.    b) The commercial version supports programs running in
  60.    LIM 4.0 expanded memory.  This version supports progams
  61.    running in conventional memory only.
  62.  
  63. The documentation accompanying this product is for the
  64. commercial version.  Therefore, disregard all references
  65. to expanded memory and related commands.
  66.  
  67. -----------------------------
  68. * To install MultiDos Plus: *
  69. -----------------------------
  70.  
  71. Print the file MDSHARE.PRN and read it before using
  72. Multidos Plus.
  73.  
  74. For a quick start type MULTIDOS to start the
  75. program.  When it is up, type a ? for a brief
  76. list of commands.  
  77.  
  78. The following is a list of new features or information
  79. not found in the manual.  Read the manual first before
  80. reading the following sections.
  81.  
  82. --------------------
  83. Command Line Options
  84. --------------------
  85.  
  86. A new command line option has been added which tells MultiDos Plus not
  87. to load the MDBIO10.EXE display BIOS.  This option may be invoked by
  88. typing /NO10 on the MultiDos Plus command line.  For example:
  89.  
  90.     MULTIDOS /NO10
  91.  
  92. This option is useful for applications which only have one task which
  93. will ever write to the display.  It may also be useful if your tasks
  94. cooperate with each other in their use of the display by using a
  95. resource semaphore to control display usage.
  96.  
  97. Please note that RS-232 output redirection is performed by the MDBIO10
  98. module.  If your application uses the COMM command to specify I/O
  99. redirection, the /NO10 option will disable the redirection of the
  100. display output.
  101.  
  102.  
  103. *** /NOMAP ***
  104.  
  105. A new option is available to disable the mapping of LIM memory into
  106. empty spaces above the C000 segment.  Use /NOMAP to disable the mapping.
  107.  
  108.  
  109. *** /NOCB ***
  110.  
  111. A new option is available to disable the checking for CTRL-C and
  112. CTRL-BREAK during DOS writes.  Use /NOCB to completely disable the
  113. checking for these two key combinations.  If this option is not used
  114. and a CTRL-C is pressed during a DOS write to the CRT display, the
  115. application may be aborted, or if if has an INT 23H handler that ignores
  116. CTRL-C or CTRL-BREAK, an ugly unexpected ^C may be displayed.
  117.  
  118. Using /NOCB makes it possible to use the ANSI.SYS functions to format
  119. and control a display without risking that the operator may enter a
  120. CTRL-C during a DOS display write.
  121.  
  122.  
  123. -----------------
  124. Operator Commands
  125. -----------------
  126.  
  127. * ASG Command *
  128.  
  129. MultiDos Plus has a feature which will enable certain keys
  130. to bring a task to the foreground immediately without using the
  131. ALT Z sequence.  The PC keyboard function keys and ALT keys may be
  132. used for this purpose.  For example, the F1 function key may be set to
  133. always bring the COMMAND task to the foreground.  Once a key assignment
  134. has been made, the task may be brought to the foreground any time the
  135. key is pressed.  The way to make this assignment is to use the ASG command.
  136.  
  137. The ASG command allows the assignment of up to 10 keys to 10 tasks.
  138. The syntax for the ASG command is:
  139.  
  140.    ASG [<task name> <index> <scan code>]
  141.  
  142. If the ASG command is entered without any arguments, a list of current
  143. key assignments will be displayed.  Each of the 10 entries in the
  144. assignment table is listed in the order: index, scan code, task name.
  145.  
  146. The arguments specify a mapping between a specified scan code and a
  147. task name.  The scan code must be specified as a decimal number.  The
  148. ASG command to map the COMMAND task to the F1 function key would be:
  149.  
  150.    ASG COMMAND 0 59
  151.  
  152. This command would set the first entry in the assignment table to
  153. map the task COMMAND to scan code 59 which is the F1 function key.
  154.  
  155. The decimal values for the function key scan codes are:
  156.  
  157.        Key    Normal Shifted   Ctrl     Alt
  158.  
  159.     F1    59    84    94    104
  160.     F2    60    85    95    105
  161.     F3    61    86    96    106
  162.     F4    62    87    97    107
  163.     F5    63    88    98    108
  164.     F6    64    89    99    109
  165.     F7    65    90    100    110
  166.     F8    66    91    101    111
  167.     F9    67    92    102    112
  168.     F10    68    93    103    113
  169.  
  170. The scan codes for other function keys and the Alt keys may also
  171. be used.
  172.  
  173. If an astrisk is used in the place of a task name, the key assignment
  174. has a different meaning.  Whenever that key is pressed, the previous
  175. foreground task is brought back to the foreground.  For example:
  176.  
  177.     ASG * 0 61
  178.  
  179. Whenever the F3 function key is pressed, the previous foreground task
  180. will be brought back to the foreground.
  181.  
  182. The value after the task name is the assignment table index and can
  183. range from 0 to 9.  Entries may be placed in any order in the table.
  184. When a key is pressed, the entry with a matching scan code closest
  185. to the begining of the table is used.
  186.  
  187. The /NALTZ command line option will not disable the single key task
  188. selection feature.
  189.  
  190.  
  191.  
  192. * BAT Command *
  193.  
  194. The BAT command will tell MultiDos Plus to execute commands from an
  195. ASCII text file as if they were entered from the keyboard.  The format
  196. is:
  197.  
  198.    BAT filename
  199.  
  200. where filename is any DOS pathname.  All commands in the file are executed
  201. by MultiDos Plus before any other commands (i.e. INT 15H, function 15)
  202. are executed.  No other task's child process requests are processed
  203. until the BAT command is finished.
  204.  
  205. A BAT batch file can also contain embeded batch commands.
  206.  
  207.  
  208.  
  209.  
  210. * FG Command *
  211.  
  212. A feature of the FG command, missing from the manual, is the ability
  213. to bring the previous foreground task back into the foreground without
  214. having to know the task's name.  If an astrisk is used in place of the
  215. task name, the previous foreground task is brought back to the foreground.
  216. This function is most useful when a task is done with the foreground and
  217. wants to switch itself to the background, restoring the task that was
  218. previously in the foreground.  The task can submit an FG command, using
  219. INT 15H function code 15, to MultiDos Plus.
  220.  
  221.  
  222.  
  223. * REM Command *
  224.  
  225. A command has been added to allow the addition of remark statements to
  226. automatic startup files.  The REM command may be added to document
  227. the content of the file.  Any characters after the REM are completly
  228. ignored.  The following are examples of some REM statements:
  229.  
  230.      REM  This is a test
  231.      REMthisisatest
  232.      REMARKABLE application written by Jack Spratt
  233.  
  234.  
  235. -----------------------------
  236. Application Program Interface
  237. -----------------------------
  238.  
  239. Several additional functions have been added to the Application Program
  240. Interface.
  241.  
  242.  * Return Memory Parameters *
  243.  
  244.      Function code = 31
  245.      Entry:
  246.          AH = 31
  247.      Exit:
  248.          BX = First memory segment of conventional memory
  249.          DX = First memory segment of the LIM swap frame
  250.               created by MultiDos Plus to load programs into
  251.  
  252.  
  253.  
  254.  * Test if Multitasking is Disabled *
  255.  
  256.      Function code = 32
  257.      Entry:
  258.          AH = 32
  259.      Exit:
  260.          AX = 0 if multitasking is enabled
  261.               or
  262.          AX = TCB of task that disabled multitasking
  263.  
  264.      This function may be useful by interrupt handlers which may need
  265.      to know if multitasking is disabled or not.
  266.  
  267.  
  268. -------------------------------------------
  269. IRQ Enhancement for LIM Tasks
  270. -------------------------------------------
  271.  
  272. The IRQ command has been enhanced to support programs with interrupt
  273. service routines in swappable LIM memory.  This includes many of the
  274. off-the-shelf communication programs as well as many other types of
  275. programs.  The enhancement added a new command line optioin and two
  276. additional MultiDos Plus commands.
  277.  
  278. The /IRQ command line option is used to enable the new features.  If
  279. MultiDos Plus is invoked without this option, the IRQ command functions
  280. as documented in the manual.  The /IRQ option must be followed by a
  281. hexadecimal value between 78 hex and F0 hex.  This option can only
  282. be used on AT type computers.  The /IRQ will tell MultiDos Plus to
  283. reprogram the 8259 interrupt controllers to use the specified vectors
  284. rather than the standard vectors.  MultiDos Plus will then intercept
  285. all the hardware interrupts and re-vector them thru the original
  286. vectors.  This allows MultiDos Plus to check if the interrupt has
  287. been associated with a task executing in swappable LIM memory and
  288. if so, map the task in before vectoring to the old vector.  When the
  289. old vector ISR has finished processing, it returns to MultiDos Plus
  290. to restore the interrupted task's memory context.
  291.  
  292. If the /IRQ option is used, the MultiDos Plus IRQ command is used to
  293. associate a hardware interrupt to the next loaded task.
  294.  
  295. For example, suppose you want to run PROCOMM in LIM memory and
  296. using a modem connected to COM1.  You also determine that nothing
  297. in your system uses the interrupt vectors 80H thru 8FH.
  298. MultiDos Plus is invoked by entering:
  299.  
  300.    MULTIDOS /IRQ 80
  301.  
  302. At the $ prompt enter the following commands:
  303.  
  304.    RM 300       (assuming your version of PROCOMM only needs 300K)
  305.    IRQ 4        (COM 1 is IRQ 4, COM 2 is IRQ 3)
  306.    PROCOMM      (assume in your current directory)
  307.  
  308. PROCOMM will be loaded in a 300K block of memory and will be associated
  309. with IRQ 4 (INT 0CH).
  310.  
  311. Two additional commands have been defined to associate or disassociate
  312. IRQs with tasks that have already been loaded.  These commands are
  313. SIRQ to associate and CIRQ to clear an association.  The SIRQ command
  314. will allow the association of more than one IRQ to a task.  The
  315. format for the SIRQ command is:
  316.  
  317.      SIRQ task irq#
  318.  
  319. and the CIRQ command is:
  320.  
  321.      CIRQ irq#
  322.  
  323. If an IRQ is already associated with a different task, SIRQ will
  324. issue an error message.
  325.  
  326. The assignment of IRQ 0 is not permitted.
  327.  
  328. When a task terminates, all IRQs associated with the task are cleared.
  329.  
  330.  
  331.  
  332. ---------------------------------------------
  333. Application Interface for Task Context Switch
  334. ---------------------------------------------
  335.  
  336. In order to provided our customers with high performance
  337. multitasking, the task context save and restore procedures save only
  338. the most necessary context required by most tasks.  Some
  339. applications may require that certain other context be preserved
  340. at every task switch.  An example might be several tasks which make
  341. use of the 8087 coprocessor.  Although the coprocessor can be treated
  342. as a resource and controlled with a semaphore, this may not be
  343. feasable (lack of source code) or practical (complex calculations
  344. in pre-existing software).  Another example might be the saving
  345. and restoring of a software interrupt needed by several tasks running
  346. in LIM memory.
  347.  
  348. An interface has been developed which allows applications to get
  349. involved in the task context switch process.  It is possible to set
  350. the entry point for two routines, one to save context and the other
  351. to restore context.  The routine to restore context will be executed
  352. just before a task is allowed to run and the routine to save context
  353. will be executed when a task's execution is suspended (end of timeslice,
  354. give up timeslice, read keyboard, suspend for interval, etc.).
  355.  
  356. The two routines are global.  e.g. All tasks must use the same routines.
  357.  
  358. Since some tasks require certain context be preserved and others do
  359. not, a flag mechanism exists to inform the context save and restore
  360. routines if and what context, if any, should be saved/restored.  A
  361. new command, MISCFLAG, has been added which is used to set bits in
  362. the MISCFLAG word (byte offset 200) in the TCB.  The format of the
  363. command is:
  364.  
  365.     MISCFLAG <hex value>
  366.  
  367. The <hex value> is masked with hex 7F to keep only the lower 7 bits
  368. and is placed in the upper byte of the miscellaneous flag word when a
  369. task is first loaded.  In other words, this command must be issued just
  370. prior to loading a task.
  371.  
  372. When MultiDos Plus saves or restores a task's context, the value
  373. specified by the MISCFLAG command is checked for non-zero.  If no
  374. MISCFLAG command is issued prior to a task load, the default value
  375. is zero.  If a non-zero value is found, the application supplied context
  376. routines are executed.
  377.  
  378. As stated earlier, the context save and restore routines are global
  379. and should probably be written as a TSR which must be executed under
  380. MultiDos Plus and must be installed in conventional memory.  A sample
  381. TSR is supplied named APPLCTX.ASM to save and restore floating point
  382. context for a real 8087 and/or Microsoft floating point emulation.  The
  383. TSR initialization code informs MultiDos Plus of the two routine's entry
  384. points by issuing a special INT 15H API call.  The following code
  385. fragment can be used to set up the entry points.  It assumes that
  386. the context save/restore routines are in the same code segment as
  387. the code fragment.
  388.  
  389.     MOV   AX,1E08H            ; FUNCTION AND SUBFUNCTION CODES
  390.     PUSH  CS
  391.     POP   DX                  ; SEGMENT OF ROUTINE CODE
  392.     MOV   BX,OFFSET CTXSAVE   ; OFFSET OF CONTEXT SAVE ROUTINE
  393.     MOV   CX,OFFSET CTXRSTR   ; OFFSET OF CONTEXT RESTORE ROUTINE
  394.     INT   15H
  395.  
  396. When either the save or restore routine is entered, ES:BX will be
  397. pointing to the task in question's TCB.  Care must be exercised not
  398. to destroy any registers.  When the routine is finished it must use
  399. a far return to return control to MultiDos Plus.
  400.  
  401. The save and restore routines can be removed from execution by
  402. executing INT 15H function 1E08H and setting the save and restore
  403. routine entry points to null (0000:0000) pointers.
  404.  
  405. A new field has been added to the TCB to aid the context save/restore
  406. routines in indexing into their context tables.  The word at byte offset
  407. 220 in the TCB has the TCB index which is a value from 0 to the number
  408. of TCBs - 1.  If the default number of TCBs (12) is configured, the largest
  409. TCB index will be 11.
  410.  
  411. If you are trying to execute several BASIC programs, you may wish to
  412. use the APPLCTX TSR as most BASIC's use floating point.
  413.  
  414. Other possible context save/restore needs might be the 32-bit registers
  415. in a 386 or the GDTR, LDTR, IDTR, etc.  This should allow the execution
  416. of multiple DOS extenders or 32-bit software.
  417.  
  418.  
  419.  
  420. --------------------------------------------------------------------
  421.  
  422.      P E R F O R M A N C E
  423.  
  424. --------------------------------------------------------------------
  425.  
  426.  
  427. If MultiDos Plus is used in an application where you have complete
  428. control of the source code, here are several tips which can be used
  429. to help you gain the maximum possible performance from the hardware
  430. which will be running your software.
  431.  
  432. Keep in mind that if a task waits for a key from the keyboard, waits
  433. for a message from a message queue, waits for an event, or waits for
  434. control of a resource semaphore, the task will not receive any time
  435. until a character, message, event or control is received.  This gives
  436. more time to other running tasks doing useful work.
  437.  
  438. Use the API function to give up your timeslice (AH = 0) where ever
  439. possible.  This function will allow another task to have a chance
  440. to run if the current task has no useful work to perform for the rest
  441. of a timeslice.  For example, if a task was displaying the current
  442. time on the display and checking for a keyboard input, it should give
  443. up its timeslice at the end of the loop if no keyboard input was
  444. received.  In addition, only get and check the time as often as
  445. realistically required.  There is no need to update the time display
  446. 18 times a second if the resolution is in minutes!
  447.  
  448. If you are using the /PR scheduling option be sure to use the API
  449. function to suspend a task (AH = 3) in order to give up a timeslice.
  450. Use of the API function (AH = 0) to give up a timeslice under this
  451. scheduling option may prohibit tasks of a lessor priority from
  452. executing because execution is given to the highest priority task
  453. in the READY queue.
  454.  
  455. If the default scheduling is used and you are setting different
  456. task priorities, be sure at least one task has a priority of zero.
  457. This will insure the maximum possible performance from the scheduling
  458. mechanism.
  459.  
  460. If you don't need the ANSI.SYS emulation for a task, turn it off
  461. using the NANSI MultiDos Plus command.  This will eliminate the
  462. overhead associated with this feature.
  463.  
  464. If a task will never use the display, use the ND command prior to
  465. loading the task .EXE or .COM.  Be sure to use the XQ command to
  466. start execution immediately after the task is loaded.
  467.  
  468. If your application only requires a single task to write to the
  469. display, use the /NO10 option to inhibit the loading of the
  470. MultiDos Plus BIOS INT 10H replacement (MDBIO10.EXE) which would
  471. not be necessary.  This would eliminate additional overhead when
  472. writing to the display.
  473.  
  474.  
  475.